﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Admin_Skin.aspx.cs" Inherits="Admin_Skin" ValidateRequest="false" %>

<%@ Register Assembly="XControl" Namespace="XControl.View" TagPrefix="cc1" %>
<%@ Register Assembly="XControl" Namespace="XControl" TagPrefix="XCL" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>无标题页</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <XCL:XGridView ID="gvSkin" runat="server" AutoGenerateColumns="False" DataKeyNames="ID"
            DataSourceID="ODSgvSkin">
            <Columns>
                <asp:TemplateField HeaderText="编号">
                    <itemstyle cssclass="IntItem" />
                    <headerstyle cssclass="IntHead" />
                    <itemtemplate>
<asp:LinkButton id="IDLinkButton1" runat="server" CommandName="Select" Text='<%# Eval("ID") %>' CausesValidation="False" __designer:wfdid="w1"></asp:LinkButton> 
</itemtemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="SkinName" HeaderText="皮肤名" SortExpression="SkinName">
                    <itemstyle cssclass="TextItem" />
                    <headerstyle cssclass="TextHead" />
                </asp:BoundField>
                <asp:BoundField DataField="Author" HeaderText="作者" SortExpression="Author">
                    <itemstyle cssclass="TextItem" />
                    <headerstyle cssclass="TextHead" />
                </asp:BoundField>
                <asp:BoundField DataField="CreateTime" HeaderText="生成时间" SortExpression="CreateTime">
                    <itemstyle cssclass="DateItem" />
                    <headerstyle cssclass="DateHead" />
                </asp:BoundField>
                <asp:BoundField DataField="Ver" HeaderText="版本" SortExpression="Ver">
                    <itemstyle cssclass="TextItem" />
                    <headerstyle cssclass="TextHead" />
                </asp:BoundField>
                <asp:BoundField DataField="Remarks" HeaderText="备注" SortExpression="Remarks" />
                <asp:CommandField ShowDeleteButton="True" ShowEditButton="True" ShowSelectButton="True" />
            </Columns>
        </XCL:XGridView>
        <asp:ObjectDataSource ID="ODSgvSkin" runat="server" DataObjectTypeName="XCMSData.Skin"
            DeleteMethod="Delete" InsertMethod="Insert" OldValuesParameterFormatString="original_{0}"
            SelectCountMethod="SelectCount" SelectMethod="SelectAll" TypeName="XCMSData.Skin"
            UpdateMethod="Update">
            <SelectParameters>
                <asp:Parameter Name="name" Type="String" />
                <asp:Parameter Name="value" Type="Object" />
                <asp:Parameter DefaultValue="0" Name="startRowIndex" Type="Int32" />
                <asp:Parameter DefaultValue="2147483647" Name="maximumRows" Type="Int32" />
            </SelectParameters>
        </asp:ObjectDataSource>
        <XCL:XFormView ID="fvSkin" runat="server" AutoRefreshXGridView="True" 
			DataKeyNames="ID" DataSourceID="ODSfvSkin" DefaultMode="Edit">
            <EditItemTemplate>
                <div id="fvSkin_Edit" class="XFormView">
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="IDLabel" runat="server" Text='<%# Eval("ID") %>'></asp:Label></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="SkinNameTextBox" runat="server" Text='<%# Bind("SkinName") %>'></asp:TextBox></div>
                        </div>
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="AuthorTextBox" runat="server" Text='<%# Bind("Author") %>'></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <XCL:DateBox ID="CreateTimeDateBox" runat="server" Text='<%# Bind("CreateTime", "{0:yyyy-MM-dd HH:mm:ss}") %>'></XCL:DateBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="VerTextBox" runat="server" Text='<%# Bind("Ver") %>'></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemValue">
                                <asp:TextBox ID="RemarksTextBox" runat="server" Height="130px" Text='<%# Bind("Remarks") %>'
                                    TextMode="MultiLine" Width="440px"></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Foot">
                        <div style="float: left">
                            <asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="true" CommandName="Update"
                                Text="更新"></asp:LinkButton></div>
                        <div style="float: left; width: 5px">
                        </div>
                        <div style="float: left">
                            <asp:LinkButton ID="UpdateCancelButton" runat="server" CausesValidation="false" CommandName="Cancel"
                                Text="取消"></asp:LinkButton></div>
                    </div>
                </div>
            </EditItemTemplate>
            <EmptyDataTemplate>
                <asp:LinkButton ID="LinkButton1" runat="server" CommandName="New">新增</asp:LinkButton>
            </EmptyDataTemplate>
            <InsertItemTemplate>
                <div id="fvSkin_Inst" class="XFormView">
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="SkinNameTextBox" runat="server" Text='<%# Bind("SkinName") %>'></asp:TextBox></div>
                        </div>
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="AuthorTextBox" runat="server" Text='<%# Bind("Author") %>'></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <XCL:DateBox ID="CreateTimeDateBox" runat="server" Text='<%# Bind("CreateTime", "{0:yyyy-MM-dd HH:mm:ss}") %>'></XCL:DateBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:TextBox ID="VerTextBox" runat="server" Text='<%# Bind("Ver") %>'></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemValue">
                                <asp:TextBox ID="RemarksTextBox" runat="server" Height="130px" Text='<%# Bind("Remarks") %>'
                                    TextMode="MultiLine" Width="440px"></asp:TextBox></div>
                        </div>
                    </div>
                    <div class="Foot">
                        <div style="float: left">
                            <asp:LinkButton ID="InsertButton" runat="server" CausesValidation="true" CommandName="Insert"
                                Text="插入"></asp:LinkButton></div>
                        <div style="float: left; width: 5px">
                        </div>
                        <div style="float: left">
                            <asp:LinkButton ID="InsertCancelButton" runat="server" CausesValidation="false" CommandName="Cancel"
                                Text="取消"></asp:LinkButton></div>
                    </div>
                </div>
            </InsertItemTemplate>
            <ItemTemplate>
                <div id="fvSkin_Item" class="XFormView">
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="IDLabel" runat="server" Text='<%# Eval("ID") %>'></asp:Label></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="SkinNameLabel" runat="server" Text='<%# Bind("SkinName") %>'></asp:Label></div>
                        </div>
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="AuthorLabel" runat="server" Text='<%# Bind("Author") %>'></asp:Label></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="CreateTimeLabel" runat="server" Text='<%# Bind("CreateTime", "{0:yyyy-MM-dd HH:mm:ss}") %>'></asp:Label></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                            <div class="ItemValue">
                                <asp:Label ID="VerLabel" runat="server" Text='<%# Bind("Ver") %>'></asp:Label></div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemName">
                                </div>
                        </div>
                    </div>
                    <div class="Row">
                        <div class="Item">
                            <div class="ItemValue">
                                <asp:Label ID="RemarksLabel" runat="server" Style="min-height: 130px; word-break: break-all"
                                    Text='<%# Bind("Remarks") %>' Width="440px"></asp:Label></div>
                        </div>
                    </div>
                    <div class="Foot">
                        <div style="float: left">
                            <asp:LinkButton ID="EditButton" runat="server" CausesValidation="false" CommandName="Edit"
                                Text="编辑"></asp:LinkButton></div>
                        <div style="float: left; width: 5px">
                        </div>
                        <div style="float: left">
                            <asp:LinkButton ID="NewButton" runat="server" CausesValidation="false" CommandName="New"
                                Text="新建"></asp:LinkButton></div>
                        <div style="float: left; width: 5px">
                        </div>
                        <div style="float: left">
                            <asp:LinkButton ID="CancelSelectButton" runat="server" CausesValidation="false" CommandName="CancelSelect"
                                Text="取消"></asp:LinkButton></div>
                    </div>
                </div>
            </ItemTemplate>
        </XCL:XFormView>
        <asp:ObjectDataSource ID="ODSfvSkin" runat="server" DataObjectTypeName="XCMSData.Skin" InsertMethod="Insert" OldValuesParameterFormatString="original_{0}" SelectMethod="FindByKey" TypeName="XCMSData.Skin" UpdateMethod="Update">
            <SelectParameters>
                <asp:ControlParameter ControlID="gvSkin" Name="__ID" PropertyName="SelectedValue"
                    Type="Int32" />
            </SelectParameters>
        </asp:ObjectDataSource>
    
    </div>
    </form>
</body>
</html>
